package library.item;

public class Movie extends Item implements LibraryItem{

	public Movie(String identifier, String author, String name, int runtime, int year) {
		super(identifier, author, name);
		this.runtime = runtime;
		this.year = year;
	}

	int runtime;
	int year;

	@Override
	public String getInfo() {
		StringBuilder info = new StringBuilder();
		info.append(runtime).append(" minutes (").append(year).append("). ASIN ").append(getIdentifier());
		info.trimToSize();
		return info.toString();
	}

	public String toString(){
		StringBuilder string =new StringBuilder();
		string.append(this.getData()).append(". ").append(this.getInfo());
		string.trimToSize();
		return string.toString();
	}

}
